ostree.git
13 years agopull-local: Fix uninitialized variable ref
Colin Walters [Thu, 21 Feb 2013 18:05:14 +0000 (13:05 -0500)]
pull-local: Fix uninitialized variable ref

13 years agoTODO: A few updates
Colin Walters [Thu, 21 Feb 2013 16:18:29 +0000 (11:18 -0500)]
TODO: A few updates

13 years agopull-local: Output status even in non-tty case
Colin Walters [Thu, 21 Feb 2013 13:54:13 +0000 (08:54 -0500)]
pull-local: Output status even in non-tty case

This way I can see progress when running builddisks.

13 years agoadmin: Use /sysroot/ostree automatically
Colin Walters [Tue, 19 Feb 2013 16:02:33 +0000 (11:02 -0500)]
admin: Use /sysroot/ostree automatically

When booted inside an ostree system, we want /sysroot/ostree, not
just /ostree by default.

13 years agoswitchroot: Use MS_MOVE to / rather than chroot
Colin Walters [Tue, 12 Feb 2013 01:46:53 +0000 (20:46 -0500)]
switchroot: Use MS_MOVE to / rather than chroot

This fixes a number of bugs; the two biggest are:

1) On shutdown systemd can correctly umount /
2) We can use linux-user-chroot inside the system, as is
   necessary to do upgrades

See http://lists.freedesktop.org/archives/systemd-devel/2012-September/006703.html

13 years agopull-deploy: Allow switching trees too
Colin Walters [Fri, 1 Feb 2013 15:56:06 +0000 (10:56 -0500)]
pull-deploy: Allow switching trees too

$ ostree admin pull-deploy gnome-ostree trees/gnomeos-3.8-x86_64-devel

Now works to switch your current tree to -devel from the current
runtime.

13 years agopull-local: Fix crasher in previous commit when not connected to tty
Colin Walters [Mon, 28 Jan 2013 20:44:13 +0000 (15:44 -0500)]
pull-local: Fix crasher in previous commit when not connected to tty

13 years agopull-local: Port to GSConsole
Colin Walters [Mon, 28 Jan 2013 20:35:47 +0000 (15:35 -0500)]
pull-local: Port to GSConsole

13 years agopull-local: Support pulling checksums too
Colin Walters [Mon, 28 Jan 2013 20:32:06 +0000 (15:32 -0500)]
pull-local: Support pulling checksums too

This matches what pull allows.

13 years agolibgsystem: Update to the latest
Colin Walters [Fri, 25 Jan 2013 20:19:34 +0000 (15:19 -0500)]
libgsystem: Update to the latest

13 years agoadmin: Don't overwrite previous ref unless it's different
Colin Walters [Thu, 24 Jan 2013 22:32:59 +0000 (17:32 -0500)]
admin: Don't overwrite previous ref unless it's different

We shouldn't overwrite deploy/<osname>/previous unless we actually
have something new.

This fixes the bug where two consecutive:

$ ostree admin upgrade foo
$ ostree admin upgrade foo

would end up pruning the data for foo/previous from the repo.

13 years agopull: Drop dead code to pad output strings too
Colin Walters [Thu, 24 Jan 2013 20:38:06 +0000 (15:38 -0500)]
pull: Drop dead code to pad output strings too

This is in GSConsole now.

13 years agoPort ostree-pull to GSConsole
Colin Walters [Thu, 24 Jan 2013 20:22:16 +0000 (15:22 -0500)]
Port ostree-pull to GSConsole

As part of this, we need to ensure our streams are inherited across
the chain of child processes.

13 years agoUpdate to the latest libgsystem
Colin Walters [Wed, 23 Jan 2013 20:20:19 +0000 (15:20 -0500)]
Update to the latest libgsystem

13 years agoadmin install: Ensure /ostree is initialized first
Colin Walters [Fri, 18 Jan 2013 13:38:09 +0000 (08:38 -0500)]
admin install: Ensure /ostree is initialized first

https://bugzilla.gnome.org/show_bug.cgi?id=692008

13 years agoadmin: Ensure /var/log/journal exists
Colin Walters [Fri, 18 Jan 2013 03:08:21 +0000 (22:08 -0500)]
admin: Ensure /var/log/journal exists

This is admittedly a hack, since the story is that services should be
handling /var on their own.  But on the other hand the current systemd
story is that admins should create it to enable it.  Possibly a better
fix is --enable-journal-always or something for systemd.

13 years agoupdate-kernel: Change dracut to use tmpdir on host, fix deploy path lookup
Colin Walters [Wed, 9 Jan 2013 09:32:51 +0000 (04:32 -0500)]
update-kernel: Change dracut to use tmpdir on host, fix deploy path lookup

We had a bit of legacy code that looked for "current" if the deploy
path was unspecified; this needs to be deploy/OSNAME/current.

Secondly, we need to point dracut at a tmpdir outside of the root when
doing FUSE, because directories with mode 0700 and owned by root:root
aren't writable.

Also update libgsystem to the latest.

13 years agoadmin: Add --no-bootloader option to update-kernel
Colin Walters [Tue, 8 Jan 2013 18:57:24 +0000 (13:57 -0500)]
admin: Add --no-bootloader option to update-kernel

Will be used by the QA scripts, since we need to inspect the kernel
configuration and generate a correct grub conf from that, rather than
trying to have update-bootloader reuse an existing config, since there
won't be one initially.

13 years agoUpdate to the latest libgsystem
Colin Walters [Tue, 8 Jan 2013 12:04:29 +0000 (07:04 -0500)]
Update to the latest libgsystem

13 years agoadmin update-kernel: Drop support for booting from host kernel
Colin Walters [Sun, 6 Jan 2013 16:47:40 +0000 (11:47 -0500)]
admin update-kernel: Drop support for booting from host kernel

Now that gnome-ostree has a kernel, this functionality is no longer
necessary.  It was always a hack.

13 years agoadmin update-kernel: Ensure initramfs has correct owner/mode
Colin Walters [Sun, 6 Jan 2013 11:43:49 +0000 (06:43 -0500)]
admin update-kernel: Ensure initramfs has correct owner/mode

It was 0600, and owned by the creating process (in the fuse case,
non-root!).  We want it 0644/root/root.

13 years agoadmin: Propagate --boot-dir to subcommands
Colin Walters [Sun, 6 Jan 2013 11:12:42 +0000 (06:12 -0500)]
admin: Propagate --boot-dir to subcommands

Really, I should be using internal functions here...

13 years agocore: Drop dead prototypes from header
Colin Walters [Sat, 5 Jan 2013 00:47:56 +0000 (19:47 -0500)]
core: Drop dead prototypes from header

Followup to previous commit.

13 years agocore: Reuse more libgsystem API in utils
Colin Walters [Sat, 5 Jan 2013 00:46:02 +0000 (19:46 -0500)]
core: Reuse more libgsystem API in utils

More code drain to libgsystem.

13 years agocore: Ensure kernel and initramfs are put into place with fdatasync()
Colin Walters [Sat, 5 Jan 2013 00:32:26 +0000 (19:32 -0500)]
core: Ensure kernel and initramfs are put into place with fdatasync()

Via a new libgsystem API.

13 years agocore: Drain fdatasync() API into libgsystem
Colin Walters [Fri, 4 Jan 2013 22:25:32 +0000 (17:25 -0500)]
core: Drain fdatasync() API into libgsystem

Just code cleanup.

13 years agoadmin: Allow specifying --boot-dir
Colin Walters [Thu, 3 Jan 2013 03:44:06 +0000 (22:44 -0500)]
admin: Allow specifying --boot-dir

This is intended for use by QA tools that want to manipulate a
loopback-mounted disk image or the like.

13 years agoadmin: restore current-etc symlink
Giovanni Campagna [Fri, 21 Dec 2012 23:21:28 +0000 (00:21 +0100)]
admin: restore current-etc symlink

It is useful now like it was before, and it is used by the grub
update script.

https://bugzilla.gnome.org/show_bug.cgi?id=690743

13 years agoRelease 2012.13
Colin Walters [Sun, 23 Dec 2012 22:36:42 +0000 (17:36 -0500)]
Release 2012.13

13 years agopull: Fix a race condition causing an early exit
Colin Walters [Sun, 23 Dec 2012 22:18:08 +0000 (17:18 -0500)]
pull: Fix a race condition causing an early exit

This is a little less magical than what we had before.

13 years agopull: Use a basic exponential moving average for bytes/sec
Colin Walters [Sun, 23 Dec 2012 19:29:15 +0000 (14:29 -0500)]
pull: Use a basic exponential moving average for bytes/sec

Still should look what other downloading programs do, but this
is better then what we had before.

13 years agoadmin: Add new run-triggers command
Colin Walters [Sat, 22 Dec 2012 18:43:44 +0000 (13:43 -0500)]
admin: Add new run-triggers command

In some cases we want the ability to run triggers independently of
checking out a tree.  For example, due to kernel limitations which
impact the gnome-ostree build system, we may need to run triggers on
first boot via systemd.

Secondarily, if the user installs a system extension which adds a new
shared library to /usr/lib for example, the system will need to run
the triggers again.

Also, I think I want to take triggers out of the core and put them in
ostree admin anyways.

13 years agoadmin: Rework /ostree/deploy to support multiple independent operating systems
Colin Walters [Wed, 19 Dec 2012 22:52:46 +0000 (17:52 -0500)]
admin: Rework /ostree/deploy to support multiple independent operating systems

The real vision of OSTree is to "multiple versions of multiple
operating systems".  Up until now, it's worked to install gnome-ostree
inside a host distribution, but several things don't work quite right
if you try to do completely different systems.

In the new model, there's the concept of an "osname" which encompasses
a few properties:

1) Its own /var
2) A set of trees deployed in /ostree/deploy/OSNAME/
3) Its own "current" and "previous" links.

Now it no longer really makes sense to boot with "ostree=current".
Instead, you specify e.g. "ostree=gnome/current".

This is an incompatible change to the deployment code - you will need
to run init-os gnome and redeploy.

All "ostree admin" subcommands now take an OSNAME argument.

13 years agoadmin: Support installing a kernel from the tree, default to it
Colin Walters [Tue, 4 Dec 2012 00:18:37 +0000 (19:18 -0500)]
admin: Support installing a kernel from the tree, default to it

The "protocol" here is rather lame; we just look for
/boot/vmlinuz-RELEASE and /lib/modules/RELEASE.  But good enough for
now.

13 years agocore: Use new libgsystem GSSubprocess API
Colin Walters [Fri, 21 Dec 2012 16:52:28 +0000 (11:52 -0500)]
core: Use new libgsystem GSSubprocess API

It's less screwing around with GPtrArray in most cases.

13 years agobuild: Set libsoup min/max defines
Colin Walters [Fri, 21 Dec 2012 16:33:05 +0000 (11:33 -0500)]
build: Set libsoup min/max defines

So we don't get warnings about soup_requester being deprecated.

13 years agocore: Pick better names for tmpfiles if no prefix given
Colin Walters [Fri, 21 Dec 2012 16:07:50 +0000 (11:07 -0500)]
core: Pick better names for tmpfiles if no prefix given

Just makes it easier to track down where files came from.

13 years agoOtWorkerQueue: Don't exit until we've fulfilled initial requests
Colin Walters [Fri, 21 Dec 2012 14:35:27 +0000 (09:35 -0500)]
OtWorkerQueue: Don't exit until we've fulfilled initial requests

This counts as an implicit "hold" on the first items, which we must
complete.  Otherwise there are race conditions where the queue may
signal idle when in fact the main process is still working.

13 years agoUpdate to latest libgsystem
Colin Walters [Fri, 21 Dec 2012 01:50:02 +0000 (20:50 -0500)]
Update to latest libgsystem

Has a bugfix change to gs_subprocess_new().

13 years agocore: Allow creating tempfile without associated output stream
Colin Walters [Fri, 21 Dec 2012 01:49:19 +0000 (20:49 -0500)]
core: Allow creating tempfile without associated output stream

Just slightly more efficient, and we'll use this for spawning curl to
a tempfile.

13 years agocore: Clean up tmpfile creation code
Colin Walters [Thu, 13 Dec 2012 20:12:51 +0000 (15:12 -0500)]
core: Clean up tmpfile creation code

I have been seeing random failures here...not entirely sure why yet,
but this code is cleaner.

13 years agoUpdate libgsystem
Colin Walters [Thu, 13 Dec 2012 20:12:33 +0000 (15:12 -0500)]
Update libgsystem

Just keeping up.

13 years agoadmin init-fs: New builtin
Colin Walters [Sun, 9 Dec 2012 22:01:51 +0000 (17:01 -0500)]
admin init-fs: New builtin

Should be used when initializing a new root filesystem for a "pure
OSTree" system; for example, what "ostbuild privhelper-deploy-qemu"
does when creating a filesystem image loopback.

13 years agoadmin: Process newly added config files recursively
Colin Walters [Fri, 7 Dec 2012 23:29:03 +0000 (18:29 -0500)]
admin: Process newly added config files recursively

Previously we just failed out if there was a new directory in /etc
added by the user (or the system).

13 years agoUpdate to the latest libgsystem
Colin Walters [Mon, 3 Dec 2012 17:05:41 +0000 (12:05 -0500)]
Update to the latest libgsystem

13 years agoUpdate to latest libgsystem
Colin Walters [Mon, 3 Dec 2012 04:02:39 +0000 (23:02 -0500)]
Update to latest libgsystem

Has a rather important bugfix.

13 years agocore: Use mmap() with O_NOATIME if merely reading archive-z2 entries
Colin Walters [Sun, 2 Dec 2012 20:20:17 +0000 (15:20 -0500)]
core: Use mmap() with O_NOATIME if merely reading archive-z2 entries

Previously we'd open(path, O_NOATIME) and do a series of small read()
calls to just parse the header.  I think this will trigger kernel readahead
into the compressed portion, but we don't care about that.

This should be more efficient.

13 years agocleanup: Rebase spawn API on top of libgsystem GSSubprocess
Colin Walters [Sat, 1 Dec 2012 21:53:06 +0000 (16:53 -0500)]
cleanup: Rebase spawn API on top of libgsystem GSSubprocess

We didn't need most the parameters anyways, so this is fewer lines of
code.  It also helps me test GSubprocess.

13 years agoUpdate to the latest libgsystem
Colin Walters [Thu, 29 Nov 2012 23:16:45 +0000 (18:16 -0500)]
Update to the latest libgsystem

13 years agoSwitch to using libgsystem shutil
Colin Walters [Thu, 29 Nov 2012 22:11:24 +0000 (17:11 -0500)]
Switch to using libgsystem shutil

More code moved into libgsystem.

13 years agoSwitch to libgsystem file reading API
Colin Walters [Thu, 29 Nov 2012 21:58:39 +0000 (16:58 -0500)]
Switch to libgsystem file reading API

More draining common utilities into libgsystem.

13 years agoSwitch to libgsystem directory creation API
Colin Walters [Thu, 29 Nov 2012 21:40:17 +0000 (16:40 -0500)]
Switch to libgsystem directory creation API

More code being dropped into a common place.

13 years agootutil: Move checksum related bits into checksum-utils.[ch]
Colin Walters [Thu, 29 Nov 2012 21:28:24 +0000 (16:28 -0500)]
otutil: Move checksum related bits into checksum-utils.[ch]

This paves the way for slimming ot-gio-utils.[ch] into libgsystem.

13 years agoDrop some bits from libotutil that are now merged in libgsystem
Colin Walters [Thu, 29 Nov 2012 21:24:49 +0000 (16:24 -0500)]
Drop some bits from libotutil that are now merged in libgsystem

13 years agolibotutil: Drop dead prototype
Colin Walters [Thu, 29 Nov 2012 20:56:17 +0000 (15:56 -0500)]
libotutil: Drop dead prototype

Was never implemented.

13 years agodeploy: With --no-kernel, do copy host kernel modules
Colin Walters [Wed, 21 Nov 2012 17:38:29 +0000 (12:38 -0500)]
deploy: With --no-kernel, do copy host kernel modules

This is used by the qemu scripts, and there we *do* need the kernel
modules inside the target system.

13 years agopull-local: Make multithreaded
Colin Walters [Mon, 19 Nov 2012 16:35:30 +0000 (11:35 -0500)]
pull-local: Make multithreaded

We were blocking for easily 1/10 or 1/5 of a second in fdatasync(),
which drastically slows down the whole process.

This threading isn't quite as good as the ostree-pull command, but it
lets us avoid the dependency on libsoup everywhere, and it's simpler.

13 years agocore: Drop old GLIB_CHECK_VERSION(2.32) bits
Colin Walters [Sun, 18 Nov 2012 20:44:21 +0000 (15:44 -0500)]
core: Drop old GLIB_CHECK_VERSION(2.32) bits

We hard require 2.34 now; if it doesn't exist on the system, that's
what embedded dependencies are for.

13 years agoadmin prune: New builtin for cleaning up deployments and repo
Colin Walters [Fri, 16 Nov 2012 22:41:46 +0000 (17:41 -0500)]
admin prune: New builtin for cleaning up deployments and repo

After a while of pull-deploy cycles, you start to accumulate a lot of
them.  While the deployment read-only part is hardlinked, the -etc
space adds up.

Additionally, the repository itself just gets large.

The new command "ostree admin prune" deletes everything except the
"current" and "previous" deployments.

13 years agodeploy: Write refs into repo for current/previous deployments
Colin Walters [Fri, 16 Nov 2012 22:14:23 +0000 (17:14 -0500)]
deploy: Write refs into repo for current/previous deployments

We don't want this data to be gc'd by default by a prune.

13 years agoprune: Report how much disk space we freed
Colin Walters [Fri, 16 Nov 2012 20:45:05 +0000 (15:45 -0500)]
prune: Report how much disk space we freed

Just nicer to see...

13 years agoprune: Add option to traverse refs only
Colin Walters [Fri, 16 Nov 2012 17:26:29 +0000 (12:26 -0500)]
prune: Add option to traverse refs only

The previous code (unintentionally) only traversed from refs; so data
only reachable from previous commits would be deleted.  That shouldn't
be the default, but we do want to offer it as an option.

So add a --refs-only option.

13 years agotraverse: Skip already traversed commits
Colin Walters [Fri, 16 Nov 2012 17:10:21 +0000 (12:10 -0500)]
traverse: Skip already traversed commits

This is just more efficient, since e.g. "ostree prune" may invoke
ostree_traverse_commit() multiple times for the same commit.

13 years agoprune: Default to deleting loose objects, code cleanup
Colin Walters [Fri, 16 Nov 2012 15:58:35 +0000 (10:58 -0500)]
prune: Default to deleting loose objects, code cleanup

We're getting closer to matching 'git gc'.

13 years agoadmin: code cleanup
Colin Walters [Fri, 16 Nov 2012 15:40:49 +0000 (10:40 -0500)]
admin: code cleanup

Refactor internal functions so they can be used by a later patch.

13 years agoostree.spec.in: Update from Fedora review comments
Colin Walters [Fri, 16 Nov 2012 15:11:39 +0000 (10:11 -0500)]
ostree.spec.in: Update from Fedora review comments

See https://bugzilla.redhat.com/show_bug.cgi?id=819951

13 years agoRelease 2012.12
Colin Walters [Thu, 1 Nov 2012 02:02:35 +0000 (22:02 -0400)]
Release 2012.12

13 years agoot-main: Ignore lt- prefixes in binary names
Jasper St. Pierre [Wed, 22 Aug 2012 08:58:17 +0000 (05:58 -0300)]
ot-main: Ignore lt- prefixes in binary names

libtool is the best

https://bugzilla.gnome.org/show_bug.cgi?id=682438

13 years agoadmin: Add new pull-deploy command
Colin Walters [Mon, 22 Oct 2012 22:23:42 +0000 (18:23 -0400)]
admin: Add new pull-deploy command

Fetch the latest for the current tree, and deploy it in one go.

13 years agolibgsystem: Update
Colin Walters [Mon, 22 Oct 2012 22:24:31 +0000 (18:24 -0400)]
libgsystem: Update

13 years agoMake ostree admin --help output more useful
Matthias Clasen [Sun, 30 Sep 2012 16:18:50 +0000 (12:18 -0400)]
Make ostree admin --help output more useful

At a minimum, it should list the available subcommands. This is
still not perfect, since there is no way to get at the help output
of the subcommands - getting that right needs more refactoring.

Signed-off-by: Colin Walters <walters@verbum.org>
13 years agocore: quiet a compiler warning
Colin Walters [Thu, 18 Oct 2012 00:54:52 +0000 (20:54 -0400)]
core: quiet a compiler warning

13 years agocore: Check out files before directories
Colin Walters [Sat, 13 Oct 2012 14:30:19 +0000 (10:30 -0400)]
core: Check out files before directories

Otherwise we pretty easily hit maximum FD limits =(

13 years agocore: Ensure correct file data is synced in non-overwrite case
Colin Walters [Mon, 15 Oct 2012 22:35:54 +0000 (18:35 -0400)]
core: Ensure correct file data is synced in non-overwrite case

13 years agocore: Use linkat() rather than link() in threaded checkouts
Colin Walters [Mon, 15 Oct 2012 14:44:20 +0000 (10:44 -0400)]
core: Use linkat() rather than link() in threaded checkouts

This seems to work around a likely Linux kernel VFS bug, where I
randomly see ENOENT on link() when we *definitely* called mkdir() at
an earlier point in time.

13 years agocore: And one more race in multithreaded mkdir -p
Colin Walters [Mon, 15 Oct 2012 14:42:18 +0000 (10:42 -0400)]
core: And one more race in multithreaded mkdir -p

Sigh =(

13 years agocore: Fix devino speedup for archive-z
Colin Walters [Sun, 14 Oct 2012 21:18:05 +0000 (17:18 -0400)]
core: Fix devino speedup for archive-z

13 years agocore: Rework archive-z mode to have header be uncompressed
Colin Walters [Sat, 13 Oct 2012 23:55:16 +0000 (19:55 -0400)]
core: Rework archive-z mode to have header be uncompressed

This is an incompatible change to archive-z, thus it is now renamed to
archive-z2 and ostree will no longer parse archive-z.

I noticed in perf that we were spending some time zlib-decompressing
file headers, which is just inefficient.  Rather than do this, keep
the headers uncompressed, and just zlib-compress content.

13 years agocore: Call fdatasync() before we rename()
Colin Walters [Sun, 14 Oct 2012 19:34:33 +0000 (15:34 -0400)]
core: Call fdatasync() before we rename()

Just noticed this from strace, doesn't really matter, but looks nicer.

13 years agocheckout: Drop uncompressed object GC for now
Colin Walters [Sat, 13 Oct 2012 23:22:29 +0000 (19:22 -0400)]
checkout: Drop uncompressed object GC for now

It's racy when multiple processes are involved, and needs a bit more
thought.

13 years agocore: Fix case where we hardlinked successfully but thought we didn't
Colin Walters [Sat, 13 Oct 2012 22:41:47 +0000 (18:41 -0400)]
core: Fix case where we hardlinked successfully but thought we didn't

We need to return hardlink_supported even if we had to do an unlink
first.

13 years agocore: A few more error-prefixings
Colin Walters [Sat, 13 Oct 2012 22:01:19 +0000 (18:01 -0400)]
core: A few more error-prefixings

13 years agocore: One more minor tweak to recursive directory creation
Colin Walters [Sat, 13 Oct 2012 21:54:19 +0000 (17:54 -0400)]
core: One more minor tweak to recursive directory creation

We would fail in the case where we were trying to create a
subdirectory of /; this didn't actually happen, just noticed
via code inspection.

13 years agocore: Prefix some error messages
Colin Walters [Sat, 13 Oct 2012 21:46:24 +0000 (17:46 -0400)]
core: Prefix some error messages

To help debug why I still have this race condition...

13 years agocore: Threadsafe recursive direction creation is harder than it appears
Colin Walters [Fri, 12 Oct 2012 21:44:02 +0000 (17:44 -0400)]
core: Threadsafe recursive direction creation is harder than it appears

13 years agocore: Fix regression in previous commit
Colin Walters [Fri, 12 Oct 2012 19:25:25 +0000 (15:25 -0400)]
core: Fix regression in previous commit

13 years agocore: Make mkdir -p function safer
Colin Walters [Fri, 12 Oct 2012 19:10:39 +0000 (15:10 -0400)]
core: Make mkdir -p function safer

Recursing here is just a more obvious way to do it, rather than
relying on the semantics of g_file_make_directory_with_parents().

13 years agocore: Ensure file data is synced to disk when checking out via non-hardlinks
Colin Walters [Fri, 12 Oct 2012 17:09:10 +0000 (13:09 -0400)]
core: Ensure file data is synced to disk when checking out via non-hardlinks

Otherwise we aren't crash-safe.

13 years agorepo: Avoid race condition in threaded checkout with symbolic links
Colin Walters [Fri, 12 Oct 2012 15:24:06 +0000 (11:24 -0400)]
repo: Avoid race condition in threaded checkout with symbolic links

We were inconsistently putting symbolic links into the uncompressed
object cache, which could cause the threaded checkout to get confused.

13 years agocore: Add dynamic uncompressed object cache for archive-z
Colin Walters [Thu, 11 Oct 2012 22:33:03 +0000 (18:33 -0400)]
core: Add dynamic uncompressed object cache for archive-z

This gives us something closer to the advantages of archive and
archive-z when using the latter.  Concretely we get deduplication
among multiple checkouts, along with the "devino" hash table trick
during commits to avoid checksumming content again.

This is enabled by default.

13 years agopull: Print elapsed time
Colin Walters [Fri, 5 Oct 2012 21:20:40 +0000 (17:20 -0400)]
pull: Print elapsed time

13 years agocore: Only do devino scan on commit (speeds up pull)
Colin Walters [Fri, 5 Oct 2012 21:12:39 +0000 (17:12 -0400)]
core: Only do devino scan on commit (speeds up pull)

When fetching data remotely, there's no point to the devino scan
because we're not going to be committing local files.

Only do it for "commit".

13 years agopull: Ensure worker queue finishes if we unhold an empty queue too
Colin Walters [Fri, 5 Oct 2012 00:32:14 +0000 (20:32 -0400)]
pull: Ensure worker queue finishes if we unhold an empty queue too

13 years agopull: Stage content asynchronously
Colin Walters [Fri, 5 Oct 2012 00:00:00 +0000 (20:00 -0400)]
pull: Stage content asynchronously

For similar reasons as metadata, this avoids having the main thread
blocked in fdatasync(), and even better - we can achieve much higher
parallelism if we have multiple threads blocked on fdatasync().

13 years agopull: Stage metadata objects asynchronously
Colin Walters [Thu, 4 Oct 2012 22:24:37 +0000 (18:24 -0400)]
pull: Stage metadata objects asynchronously

This avoids the main thread being blocked on fdatasync(); also as a
bonus we checksum metadata in a separate thread too.

13 years agopull: Ensure queued filemeta requests don't starve everything else
Colin Walters [Thu, 4 Oct 2012 22:23:18 +0000 (18:23 -0400)]
pull: Ensure queued filemeta requests don't starve everything else

We need this hack for "archive mode" repositories; otherwise,
what ends up happening is that we get 10000+ requests pending
for .filemeta files, which we can't process until we also get
the .filecontent.

Note this hack is unneccessary when fetching from archive-z
repositories.

13 years agopull: Merge metadata and content fetch phases
Colin Walters [Thu, 4 Oct 2012 19:29:39 +0000 (15:29 -0400)]
pull: Merge metadata and content fetch phases

This is a notable speedup when the metadata scanner is working, and we
don't have a lot of traffic; we can pull down data at the same time.

13 years agopull: Asynchronous metadata fetch
Colin Walters [Tue, 28 Aug 2012 13:41:09 +0000 (09:41 -0400)]
pull: Asynchronous metadata fetch

Create a worker thread for processing metadata, reserving the main
thread for HTTP requests.

This can create a very significant efficiency win for large pull
requests since we are much more likely to keep a full pipeline open.

The status display is also nicer now.

13 years agoadmin: Install grub2 config file if we detect /etc/grub.d
Colin Walters [Mon, 1 Oct 2012 23:34:25 +0000 (19:34 -0400)]
admin: Install grub2 config file if we detect /etc/grub.d

Decouple this from the kernel postinst one, since it's possible to
have one but not the other.

13 years agoadmin: Prepare /var/log/dracut.log when creating initramfs
Colin Walters [Mon, 1 Oct 2012 14:25:36 +0000 (10:25 -0400)]
admin: Prepare /var/log/dracut.log when creating initramfs

Otherwise dracut complains.